Open
Conversation
Owner
vijit101
commented
Sep 21, 2019
- Cleaned some code
- Added UI
- Added missing pieces
mayankgrover
suggested changes
Sep 21, 2019
| { | ||
| public class ShootingState : TankState | ||
| { | ||
| bool Enterstate; |
There was a problem hiding this comment.
why do you need this enter state?
There was a problem hiding this comment.
the component is disabled when you exit the state - so update won't get called anyways!
| { | ||
| enemyBehaviour.AddHealth(100); | ||
| BulletController EnemyBullet = BulletService.Instance.GetBullet(TankType.LowHealth); | ||
| enemyBehaviour.AddHealth((int)EnemyBullet.BulletModel.Damage); |
There was a problem hiding this comment.
addhealth? function name doesn't seem to be correct - why would you add health to an enemy ? :)
| TankModel = tankModel; | ||
| // Setting the mdoel to view | ||
| TankModel = tankModel; // points to a refrence(address) of tankModel and even if defaultmodel = new tankmodel; default = tank model still points | ||
| DefaultModel = new TankModel(tankModel.Type,(int)tankModel.Speed,(int)tankModel.Health); |
| @@ -0,0 +1,23 @@ | |||
| using UnityEngine; | |||
| using TMPro; | |||
| public class EndScoreScript : MonoBehaviour | |||
There was a problem hiding this comment.
no need to name scripts with the word script
| using System.Collections.Generic; | ||
| using UnityEngine; | ||
|
|
||
| public class SceneSwitcher : MonoBehaviour |
There was a problem hiding this comment.
does this need to be a monobehaviour ?
There was a problem hiding this comment.
why do you even need this script? you can call LevelLoader directly
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.